package cn.iocoder.yudao.module.reading.controller.admin.banner.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import java.time.LocalDateTime;

/**
 * 管理后台 - 横幅管理更新 Request VO
 *
 * @author 李晨
 */
@Schema(description = "管理后台 - 横幅管理更新 Request VO")
@Data
public class BannerUpdateReqVO {

    @Schema(description = "横幅ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "横幅ID不能为空")
    private Long id;

    @Schema(description = "横幅标题", requiredMode = Schema.RequiredMode.REQUIRED, example = "🎉 暑假限时特价活动")
    @NotBlank(message = "横幅标题不能为空")
    @Size(max = 100, message = "横幅标题长度不能超过100个字符")
    private String title;

    @Schema(description = "横幅描述", example = "精选绘本集5折起，快来抢购吧！")
    @Size(max = 200, message = "横幅描述长度不能超过200个字符")
    private String description;

    @Schema(description = "横幅图片URL", requiredMode = Schema.RequiredMode.REQUIRED, example = "https://example.com/banner.jpg")
    @NotBlank(message = "横幅图片不能为空")
    @Size(max = 500, message = "横幅图片URL长度不能超过500个字符")
    private String imageUrl;

    @Schema(description = "跳转链接URL", example = "/pages/category/index?category=special")
    @Size(max = 500, message = "跳转链接URL长度不能超过500个字符")
    private String linkUrl;

    @Schema(description = "链接类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "internal")
    @NotBlank(message = "链接类型不能为空")
    private String linkType;

    @Schema(description = "排序权重", requiredMode = Schema.RequiredMode.REQUIRED, example = "100")
    @NotNull(message = "排序权重不能为空")
    private Integer sortOrder;

    @Schema(description = "状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "true")
    @NotNull(message = "状态不能为空")
    private Boolean status;

    @Schema(description = "开始展示时间", example = "2025-01-01T00:00:00")
    private LocalDateTime startTime;

    @Schema(description = "结束展示时间", example = "2025-03-31T23:59:59")
    private LocalDateTime endTime;

}
